<?php

namespace Wechat\Helper;


use Hyperf\Utils\Context;
use Hyperf\WebSocketServer\Context as WsContext;

class Helper
{


    public static function getFd(){
        return  Context::get(WsContext::FD);
    }

    public static function send($fd,$data){
        App(Sender::class)->getSender()->push($fd,json_encode($data));
    }
}